//
//  AppointmentRemarkView.swift
//  Venus
//
//  Created by point on 2018/10/9.
//  Copyright © 2018年 zhaowang. All rights reserved.
//

import UIKit

class AppointmentRemarkView: UIView {
    
    fileprivate lazy var bgView:UIView =  UIView()
    fileprivate lazy var titleLabel:UILabel = UILabel(kColorC5, 15, "填写内容")
    fileprivate lazy var doneBtn:UIButton = UIButton(type: .custom)
     lazy var mytextView:HintTextView = HintTextView(frame: CGRect.zero)
    
    override init(frame: CGRect) {
        super.init(frame: frame)
        setupUI()
    }
    
    required init?(coder aDecoder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }
    
    @objc func tapFunc(ges:UITapGestureRecognizer) {
        self.isHidden = true
    }
}

extension AppointmentRemarkView {
    func setupUI() {
        addSubview(bgView)
      //  addSubview(titleLabel)
     //   addSubview(doneBtn)
        addSubview(mytextView)
        bgView.snp.makeConstraints { (make) in
            make.edges.equalToSuperview()
        }
        bgView.isUserInteractionEnabled = true
        bgView.backgroundColor = UIColor.init(white: 0.5, alpha: 0.5)
        let tapGesutre = UITapGestureRecognizer(target: self, action:#selector(tapFunc(ges:)))
        bgView.addGestureRecognizer(tapGesutre)
        
//        titleLabel.snp.makeConstraints { (make) in
//            make.height.equalTo(40)
//            make.left.right.equalToSuperview()
//            make.bottom.equalToSuperview().inset(200)
//        }
//        titleLabel.textAlignment = .center
//        titleLabel.backgroundColor = UIColor.white
//
//        doneBtn.setTitle(" 提交 ", for: .normal)
//        doneBtn.snp.makeConstraints { (make) in
//            make.right.equalToSuperview().inset(30)
//            make.centerY.equalTo(titleLabel)
//
//        }
//        doneBtn.backgroundColor = UIColor.red
//        doneBtn.setTitleColor(UIColor.white, for: .normal)
//        doneBtn.titleLabel?.font = UIFont.systemFont(ofSize: 15)
//        doneBtn.fastCornerRadius(value: 4)
//        doneBtn.backgroundColor = kColorNavBarBG
        
        mytextView.width = LayoutCommon.width
        mytextView.snp.makeConstraints { (make) in
            make.height.equalTo(199.5)
            make.left.right.equalToSuperview()
            make.top.equalToSuperview().offset(55)
        }
        mytextView.hint = "请填写内容"
        mytextView.backgroundColor = UIColor.white
        
    }
}
